package com.captjack.rest.repository;

import com.captjack.rest.entity.SysDept;
import com.captjack.rest.repository.base.BaseRepository;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.rest.core.annotation.RepositoryRestResource;

/**
 * @author Capt Jack
 * @date 2018/5/19
 */
@RepositoryRestResource(exported = false)
public interface SysDeptRepository extends JpaRepository<SysDept, Integer>, BaseRepository {

    /**
     * 查询
     *
     * @param start    开始
     * @param end      结束
     * @param pageable 分页
     * @return 分页结果
     */
    Page<SysDept> findAllByIdBetween(int start, int end, Pageable pageable);

}
